FROM ubuntu:16.04

RUN apt-get update
RUN apt-get update
RUN apt-get install -y --no-install-recommends --allow-unauthenticated \
		supervisor

RUN apt-get install -y --no-install-recommends --allow-unauthenticated \
		nginx

ADD sites-enabled/ /etc/nginx/sites-enabled
ADD etc /var/www/app/etc
WORKDIR /var/www/app

RUN cp /var/www/app/etc/supervisor/conf.d/webapp.conf /etc/supervisor/conf.d/

CMD ["supervisord", "-n", "-c", "/etc/supervisor/supervisord.conf"]